<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
<script type="text/javascript">
	$(document).ready(function() {
		$("#save").button().click(function() {
			if($("#oldPwd").val()==''){
				alert('旧密码不能为空！');
				return false;
			}
			if($("#pwd1").val()==''){
				alert('新密码不能为空！');
				return false;
			}
			if($("#pwd2").val()==''){
				alert('确认密码不能为空！');
				return false;
			}
			if($("#pwd1").val()!=$("#pwd2").val()){
				alert('新密码和确认密码不相等！');
				return false;
			}
			$('#f').ajaxSubmit(function(data){
                alert(data);
            });
            return false;
		});
	});
</script>
<div class="content">
	<form action="./myPwd.do" id="f" method="post">
<fieldset>
	<legend>修改密码</legend>
		<div><label>旧密码：</label><input type="password" name="oldPwd" id="oldPwd" ></div>
		<div><label>新密码：</label><input type="password" name="pwd1" id="pwd1"></div>
		<div><label>确认密码：</label><input type="password" name="pwd2" id="pwd2"></div>
</fieldset>
</form>
<button id="save">保存</button>
</div>
